Repository navigation
fix(tmux): 入れ子の tmux のコピーを手元のクリップボードへ届ける(#528) - #529
Merged
Merged
Conversation
base の tmux の既定に set -s set-clipboard on を足し、ペインの中のプログラムが送る OSC 52 を外側の端末へ中継する。既定の external では、内側の tmux の Ctrl+C のコピーを 外側の tmux が捨てていた。 テストは実効値の確認に加え、別ソケットで外側と内側の tmux を組み、内側の set-buffer -w が 外側のバッファに届くことを確かめる(変更前の設定では落ちる)。仕様書に入れ子の場合を書き足した。 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KYHP834rrrDgS7unQBUYSj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概要
Closes #528
tmux の中でさらに tmux を動かすと(入れ子)、内側の tmux の
Ctrl+Cのコピーが手元の PC のクリップボードに届かなかった。外側の tmux のset-clipboardが既定のexternalのままで、ペインの中から来た OSC 52 を捨てていたため。変更
containers/base/tmux.confset -s set-clipboard onを足す。理由・読み取りはできないこと・戻し方をコメントに書いたtests/containers/test_tmux_conf.pyonであることのテストと、別ソケットで外側・内側の tmux を組み、内側のset-buffer -wが外側のバッファに届くことのテストを足すdocs/specifications/kiro-auth-persistence-and-tmux-copy.mdCHANGELOG.md[Unreleased]の Fixed に足す設計と違う点
考慮したこと
onにすると、ペインの中のプログラムは OSC 52 でクリップボードを書き換えられる。読み取りはできない(tmux は OSC 52 の問い合わせに答えない)~/.tmux.confにset -s set-clipboard externalと書けば戻せる(/etc/tmux.confの後に読まれる)確かめたこと
env -u DEVBASE_ROOT uv run --locked pytest tests/ -q: 4886 passed, 25 skippedmainのtmux.confに戻すと落ち(10 秒待って届かない)、変更後は通る(手元の tmux 3.4)uvx ruff check --select=E9,F63,F7,F82 lib: All checks passed🤖 Generated with Claude Code
https://claude.ai/code/session_01KYHP834rrrDgS7unQBUYSj